<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no">
    <title>三更海鲜夜宵外卖</title>
    <link rel="stylesheet" href="css/libs/weui.css">
    <link rel="stylesheet" href="css/project.css">
    <script src="js/libs/jquery-3.0.0.min.js"></script>
    <script src="js/libs/weui.js"></script>
    <script src="js/project.js"></script>

    <style>
        body{font-size: 0px;}
        a:active{background: none!important;}
        img.bg{width: 100%;height: 75px;}
        .content{position: relative;height: 202px;border-bottom: solid 1px #adaaac;background-color: #fff;}
        .content .step{position: absolute;left: 30px;top:33px;}
        .content .weui_cells{position: absolute;left: 80px;right: 0;margin: 0;}
        .weui_cells:before,.weui_cells:after{display: none;}
        .weui_cell{height: 100px;}
        .weui_label{font-size: 17px;display: inline-block;width: 80px;}
        .weui_cell_ft.data{text-align: left;}
        .weui_cell_ft.data:after{display: none;}
        .weui_cell_ft.data .weui_input{width: 85%;}
        .weui_cell_hd img{margin-right: 10px;}

        .submit{display: inline-block;margin: 15px auto;}
        .fix-bottom{position: fixed;bottom: 20px;left:0;right:0;text-align: center;font-size: 14px;}
        .fix-bottom p:first-child{text-decoration: underline;}
    </style>
</head>
<body>
<img class="bg" src="images/page1/guanggao.png">

<div class="content">
    <img class="step" width="30" height="130" src="images/page1/step.png">

    <div class="weui_cells weui_cells_access">
        <a class="weui_cell" href="page2-myAddress.html">
            <div class="weui_cell_hd">
                <img width="20" height="20" src="images/page1/icon1.png">
            </div>
            <div class="weui_cell_bd weui_cell_primary">
                <label for="" class="weui_label">送餐地址</label>
            </div>
            <div class="weui_cell_ft"></div>
        </a>
        <div id="address" style="margin-top:-23px;text-indent: 30px;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;color: #999; "></div>

        <a class="weui_cell">
            <div class="weui_cell_hd"><img width="20" height="20" src="images/page1/icon2.png"></div>
            <div class="weui_cell_bd"><label for="date" class="weui_label">用餐时间</label></div>
            <div class="weui_cell_ft data weui_cell_primary">
                <input id="date" class="weui_input" type="date" value="">
            </div>
        </a>
    </div>
</div>

<div style="text-align: center;">
    <a href="page4-menu.html" class="submit"><img width="230" height="75" src="images/page1/bg_btn.png"></a>
</div>

<div class="fix-bottom">
    <p>【客服热线:400-800-3333】帮您下单！</p>
    <p>营业时间:17:00~凌晨2:00</p>
</div>

    <script>

        $(function () {
            var defaultAddress ;
            var addressList = store.getItem('addressList');
            var eatingDate = store.getItem('eatingDate');
            //初始化数据
            addressList.forEach(function (item) {
                if(item.selected){
                    defaultAddress = item.city+item.detail;
                }
            });
            $('#address').text(defaultAddress);
            $('#date').val(eatingDate);

            // 绑定事件
            $('#date').on('change', function () {
                store.setItem('eatingDate',$('#date').val());
            })

        })
    </script>
</body>
</html>